home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1994 August: Tool Chest / Dev.CD Aug 94.toast / Sample Code / Newton Sample Code 1.1 / Views / Paragraph Scroll-2 / ParagraphScroll.text < prev    next >
Encoding:
Text File  |  1994-02-28  |  1.6 KB  |  74 lines  |  [TEXT/MPS ]

  1.  
  2. // ---- End Project Data ----
  3.  
  4.  
  5. // ---- File ParagraphScroll.t ----
  6.  
  7. // Before Script for "mainView"
  8. // Copyright 1993-1994 Apple Computer. All rights reserved.
  9.  
  10. mainView :=
  11.    {viewFlags: 1,
  12.     viewFormat: 593,
  13.     viewBounds: {left: 4, top: 4, right: 228, bottom: 180},
  14.     declareSelf: 'base,
  15.     viewclass: 74,
  16.     debug: "mainView"
  17.    };
  18.  
  19. _view000 := /* child of mainView */ {_proto: protoClosebox};
  20.  
  21.  
  22.  
  23. scrollClipper := /* child of mainView */
  24.    {viewFlags: 67108899,
  25.     viewFormat: 337,
  26.     viewBounds: {left: 1, top: 1, right: 239, bottom: 159},
  27.     viewSetupDoneScript:
  28.       func()
  29.       begin
  30.          :SetupIdle(1);
  31.       end,
  32.     viewIdleScript:
  33.       func()
  34.       begin
  35.          :SetOrigin(self.viewOriginX,self.viewOriginY + 1); //Slide child up by one
  36.           1
  37.       //This should return the number of milliseconds to delay. NIL if no more idling.
  38.       end,
  39.     viewOriginX: 0,
  40.     viewOriginY: 0,
  41.     viewclass: 74,
  42.     debug: "scrollClipper"
  43.    };
  44. // View scrollClipper is declared to mainView
  45.  
  46. theTextView := /* child of scrollClipper */
  47.    {viewFlags: 11,
  48.     viewFormat: 257,
  49.     viewlinespacing: 20,
  50.     viewFont: rom_fontsystem14bold,
  51.     viewBounds: {left: 0, top: 0, right: 224, bottom: 48},
  52.     text: "Text\n",
  53.     viewSetupFormScript:
  54.       func()
  55.       begin
  56.          for i := 1 to 200 do text := text & GetRandomWord(4,10) & " " ;
  57.           //Creates the actual paragraph o' text.
  58.       end,
  59.     viewclass: 81,
  60.     debug: "theTextView"
  61.    };
  62. // View theTextView is declared to scrollClipper
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72. // ---- Beginning of section for non used Layout files ----
  73.  
  74. // End of output